//
//  ZXFSocietyController.m
//  163News
//
//  Created by Eden on 25/2/16.
//  Copyright © 2016年 Eden. All rights reserved.
//
#define RandomColor  [UIColor colorWithRed:arc4random() %256/255.0 green:arc4random()%256/255.0 blue:arc4random()%256/255.0 alpha:1]

#import "ZXFSocietyController.h"

@interface ZXFSocietyController ()

@end

@implementation ZXFSocietyController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    self.view.backgroundColor = RandomColor;
    
}

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
    return 20;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    static NSString *ID = @"cell";
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:ID];
    if (cell == nil) {
        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:ID];
    }
    
    cell.textLabel.text = [NSString stringWithFormat:@"%@ ---%zd",self.title,indexPath.row];
    return cell;
}

@end
